package com.guigu.service;

import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.baomidou.mybatisplus.extension.service.IService;
import com.guigu.pojo.ShopInfo;
import org.springframework.web.multipart.MultipartFile;

import javax.servlet.http.HttpServletRequest;
import java.util.List;
import java.util.Map;

public interface ShopInfoService extends IService<ShopInfo> {

    //添加商品
    Map addShop(ShopInfo shop, MultipartFile[] imgs, HttpServletRequest request);

    //分页及所有
    Page<ShopInfo> queryAllShops(ShopInfo shop, Integer pageno, Integer pagesize);

    //获取商品编号
    List<String> getIds(String str);

    //修改商品上架下架
    Map isUp(ShopInfo shop);

    //修改商品信息
    Map editShopById(ShopInfo shop, MultipartFile[] files, String[] filenames, HttpServletRequest request);

    //id查询商品
    ShopInfo queryShopById(Integer id);

    //删除商品
    Map deleteShopById(ShopInfo shop);
}
